Optimal. Leaf size=73 \[ \frac {a^3 \tanh ^{-1}(\sin (c+d x))}{d}+\frac {1}{2} b x \left (6 a^2+b^2\right )+\frac {5 a b^2 \sin (c+d x)}{2 d}+\frac {b^2 \sin (c+d x) (a+b \cos (c+d x))}{2 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.11, antiderivative size = 73, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.210, Rules used = {2793, 3023, 2735, 3770} \[ \frac {1}{2} b x \left (6 a^2+b^2\right )+\frac {a^3 \tanh ^{-1}(\sin (c+d x))}{d}+\frac {5 a b^2 \sin (c+d x)}{2 d}+\frac {b^2 \sin (c+d x) (a+b \cos (c+d x))}{2 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2735
Rule 2793
Rule 3023
Rule 3770
Rubi steps
\begin {align*} \int (a+b \cos (c+d x))^3 \sec (c+d x) \, dx &=\frac {b^2 (a+b \cos (c+d x)) \sin (c+d x)}{2 d}+\frac {1}{2} \int \left (2 a^3+b \left (6 a^2+b^2\right ) \cos (c+d x)+5 a b^2 \cos ^2(c+d x)\right ) \sec (c+d x) \, dx\\ &=\frac {5 a b^2 \sin (c+d x)}{2 d}+\frac {b^2 (a+b \cos (c+d x)) \sin (c+d x)}{2 d}+\frac {1}{2} \int \left (2 a^3+b \left (6 a^2+b^2\right ) \cos (c+d x)\right ) \sec (c+d x) \, dx\\ &=\frac {1}{2} b \left (6 a^2+b^2\right ) x+\frac {5 a b^2 \sin (c+d x)}{2 d}+\frac {b^2 (a+b \cos (c+d x)) \sin (c+d x)}{2 d}+a^3 \int \sec (c+d x) \, dx\\ &=\frac {1}{2} b \left (6 a^2+b^2\right ) x+\frac {a^3 \tanh ^{-1}(\sin (c+d x))}{d}+\frac {5 a b^2 \sin (c+d x)}{2 d}+\frac {b^2 (a+b \cos (c+d x)) \sin (c+d x)}{2 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.14, size = 105, normalized size = 1.44 \[ \frac {-4 a^3 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )+4 a^3 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )+\cos \left (\frac {1}{2} (c+d x)\right )\right )+2 b \left (6 a^2+b^2\right ) (c+d x)+12 a b^2 \sin (c+d x)+b^3 \sin (2 (c+d x))}{4 d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.85, size = 72, normalized size = 0.99 \[ \frac {a^{3} \log \left (\sin \left (d x + c\right ) + 1\right ) - a^{3} \log \left (-\sin \left (d x + c\right ) + 1\right ) + {\left (6 \, a^{2} b + b^{3}\right )} d x + {\left (b^{3} \cos \left (d x + c\right ) + 6 \, a b^{2}\right )} \sin \left (d x + c\right )}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.51, size = 137, normalized size = 1.88 \[ \frac {2 \, a^{3} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - 2 \, a^{3} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) + {\left (6 \, a^{2} b + b^{3}\right )} {\left (d x + c\right )} + \frac {2 \, {\left (6 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 6 \, a b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{2}}}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.08, size = 90, normalized size = 1.23 \[ \frac {a^{3} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{d}+3 a^{2} b x +\frac {3 a^{2} b c}{d}+\frac {3 a \,b^{2} \sin \left (d x +c \right )}{d}+\frac {b^{3} \cos \left (d x +c \right ) \sin \left (d x +c \right )}{2 d}+\frac {b^{3} x}{2}+\frac {c \,b^{3}}{2 d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.34, size = 69, normalized size = 0.95 \[ \frac {12 \, {\left (d x + c\right )} a^{2} b + {\left (2 \, d x + 2 \, c + \sin \left (2 \, d x + 2 \, c\right )\right )} b^{3} + 4 \, a^{3} \log \left (\sec \left (d x + c\right ) + \tan \left (d x + c\right )\right ) + 12 \, a b^{2} \sin \left (d x + c\right )}{4 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.72, size = 123, normalized size = 1.68 \[ \frac {2\,a^3\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {b^3\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {b^3\,\sin \left (2\,c+2\,d\,x\right )}{4\,d}+\frac {3\,a\,b^2\,\sin \left (c+d\,x\right )}{d}+\frac {6\,a^2\,b\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \cos {\left (c + d x \right )}\right )^{3} \sec {\left (c + d x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________